#ifndef IPSET_H
#define IPSET_H

#include <QMainWindow>
#include "ipset_interface.h"
#include <QObject>
#include <QThread>
#include <QDebug>
#include <QProcess>
#include <QLabel>
#include <QFile>
#include <QDir>
#include <QMovie>
#include <QScreen>
#include <QScrollBar>
#include <QListWidget>
#include <QInputDialog>
#include <QDialog>
#include <QMessageBox>
#include <QFileInfo>
#include <database.h>

namespace Ui {
class ipset;
}

class ipset : public QMainWindow
{
    Q_OBJECT

public:
    explicit ipset(QWidget *parent = 0);
    ~ipset();

    void showEvent(QShowEvent * event);
    void languageReload();
    void setIpFont();
    void setIpText();
    void setDnsText();
    void setSwitchText();
    void getEthernetPort();
    void setAutoIp();
    void setStaticIp();

signals:
    void ipset_back_msg();

private slots:
    void switch_change_flag(bool flag);
    void on_btn_ret_clicked();
    void on_btn_ipShow_clicked();
    void on_btn_setIp_clicked();
    void on_btn_cancel_clicked();
    void on_btn_ok_clicked();
    void on_rdbtn_staticIP_clicked();
    void on_rdbtn_autoIP_clicked();
    void on_rdbtn_autoDns_clicked();
    void on_rdbtn_setDns_clicked();

private:
    Ui::ipset *ui;
    database g_database;
};

#endif // IPSET_H
